package com.xh.bussiness.course.service;

import com.xh.bussiness.course.bean.request.CourseChapterRequest;
import com.xh.bussiness.course.model.CourseChapter;
import com.xh.bussiness.resource.bean.dto.MaterialDto;
import com.xh.core.service.IBaseService;

import java.util.List;
import java.util.Map;

public interface ICourseChapterService extends IBaseService<CourseChapter> {

    List<CourseChapter> queryAll(CourseChapterRequest request);

    boolean add(CourseChapterRequest request);

    Map<String, Long> queryMaterialCountByType(String userId, String courseIndexId);

    List<MaterialDto> queryMaterialByCourseIndex(String userId, String courseIndexId, Integer type);

    boolean deleteByCourseIndexId(String courseIndexId, String chapterId);
}
